home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 5 / Amiga Tools 5.iso / tools / developer-tools / andere sprachen / perl5 / perl5.002 / hints / os2.sh < prev    next >
Encoding:
Text File  |  1996-02-15  |  3.5 KB  |  139 lines

  1. # hints/os2.sh
  2. # This file reflects the tireless work of
  3. # Ilya Zakharevich <ilya@math.ohio-state.edu>
  4. #
  5. # Trimmed and comments added by 
  6. #     Andy Dougherty  <doughera@lafcol.lafayette.edu>
  7. #     Exactly what is required beyond a standard OS/2 installation?
  8. #     There are notes about "patched pdksh" I don't understand.
  9.  
  10. # Note that symbol extraction code gives wrong answers (sometimes?) on
  11. # gethostent and setsid.
  12.  
  13. # Note that during the .obj compile you need to move the perl.dll file
  14. # to LIBPATH :-(
  15.  
  16. #osname="OS/2"
  17. sysman=`../UU/loc . /man/man1 c:/man/man1 c:/usr/man/man1 d:/man/man1 d:/usr/man/man1 e:/man/man1 e:/usr/man/man1 f:/man/man1 f:/usr/man/man1 g:/man/man1 g:/usr/man/man1 /usr/man/man1`
  18. cc='gcc'
  19. usrinc='/emx/include'
  20. libemx="`../UU/loc . X c:/emx/lib d:/emx/lib e:/emx/lib f:/emx/lib g:/emx/lib h:/emx/lib /emx/lib`"
  21.  
  22. if test "$libemx" = "X"; then echo "Cannot find C library!"; fi
  23.  
  24. libpth="$libemx/st $libemx"
  25.  
  26. so='dll'
  27.  
  28. # Additional definitions:
  29.  
  30. firstmakefile='GNUmakefile'
  31. exe_ext='.exe'
  32.  
  33. if [ "$emxaout" != "" ]; then
  34.     d_shrplib='undef'
  35.     obj_ext='.o'
  36.     lib_ext='.a'
  37.     ar='ar'
  38.     plibext='.a'
  39.     d_fork='define'
  40.     lddlflags='-Zdll'
  41.     ldflags='-Zexe'
  42.     ccflags='-DDOSISH -DNO_SYS_ALLOC -DOS2=2 -DEMBED -I.'
  43.     use_clib='c'
  44. else
  45.     d_shrplib='define'
  46.     obj_ext='.obj'
  47.     lib_ext='.lib'
  48.     ar='emxomfar'
  49.     plibext='.lib'
  50.     d_fork='undef'
  51.     lddlflags='-Zdll -Zomf -Zcrtdll'
  52.     ldflags='-Zexe -Zomf -Zcrtdll'
  53.     ccflags='-Zomf -DDOSISH -DOS2=2 -DEMBED -I.'
  54.     use_clib='c_import'
  55. fi
  56.  
  57. # To get into config.sh (should start at the beginning of line)
  58. # or you can put it into config.over.
  59. plibext="$plibext"
  60.  
  61. #libc="/emx/lib/st/c_import$lib_ext"
  62. libc="$libemx/st/$use_clib$lib_ext"
  63.  
  64. if test -r "$libemx/c_alias$lib_ext"; then 
  65.     libnames="$libemx/c_alias$lib_ext"
  66. fi
  67. # otherwise puts -lc ???
  68.  
  69. # [Maybe we should just remove c from $libswanted ?]
  70.  
  71. libs='-lsocket -lm'
  72. archobjs="os2$obj_ext"
  73.  
  74. # Run files without extension with sh - feature of patched ksh
  75. # [???]
  76. NOHASHBANG=sh
  77. # Same with newer ksh
  78. EXECSHELL=sh
  79.  
  80. cccdlflags='-Zdll'
  81. dlsrc='dl_os2.xs'
  82. ld='gcc'
  83. usedl='define'
  84.  
  85. #cppflags='-DDOSISH -DOS2=2 -DEMBED -I.'
  86.  
  87. # for speedup: (some patches to ungetc are also needed):
  88. # Note that without this guy tests 8 and 10 of io/tell.t fail, with it 11 fails
  89.  
  90. stdstdunder=`echo "#include <stdio.h>" | cpp | egrep -c "char +\* +_ptr"`
  91. d_stdstdio='define'
  92. d_stdiobase='define'
  93. d_stdio_ptr_lval='define'
  94. d_stdio_cnt_lval='define'
  95.  
  96. if test "$stdstdunder" = 0; then
  97.   stdio_ptr='((fp)->ptr)'
  98.   stdio_cnt='((fp)->rcount)'
  99.   stdio_base='((fp)->buffer)'
  100.   stdio_bufsiz='((fp)->rcount + (fp)->ptr - (fp)->buffer)'
  101.   ccflags="$ccflags -DMYTTYNAME"
  102.   myttyname='define'
  103. else
  104.   stdio_ptr='((fp)->_ptr)'
  105.   stdio_cnt='((fp)->_rcount)'
  106.   stdio_base='((fp)->_buffer)'
  107.   stdio_bufsiz='((fp)->_rcount + (fp)->_ptr - (fp)->_buffer)'
  108. fi
  109.  
  110. # to put into config.sh
  111. myttyname="$myttyname"
  112.  
  113. # To have manpages installed
  114. nroff='nroff.cmd'
  115. # above will be overwritten otherwise, indented to avoid config.sh
  116.   _nroff='nroff.cmd'
  117.  
  118. ln='cp'
  119. # Will be rewritten otherwise, indented to not put in config.sh
  120.   _ln='cp'
  121. lns='cp'
  122.  
  123. nm_opt='-p'
  124.  
  125. ####### All the rest is commented
  126.  
  127. # I do not have these:
  128. #dynamic_ext='Fcntl GDBM_File SDBM_File POSIX Socket UPM REXXCALL'
  129. #dynamic_ext='Fcntl POSIX Socket SDBM_File Devel/DProf'
  130. #extensions='Fcntl GDBM_File SDBM_File POSIX Socket UPM REXXCALL'
  131. #extensions='Fcntl SDBM_File POSIX Socket Devel/DProf'
  132.  
  133. # The next two are commented. pdksh handles #!
  134. # sharpbang='extproc '
  135. # shsharp='false'
  136.  
  137. # Commented:
  138. #startsh='extproc ksh\\n#! sh'
  139.